<% present entry do |entry_presenter| %>
    <%= content_tag :div, class: "read toolbar-wrap", data: {behavior: "selected_entry_data", entry_id: entry.id} do %>
        <%= text_area_tag "source_link_field", entry.fully_qualified_url, class: "visually-hidden" %>
        <div class="entry-toolbar">
            <div class="site-info">
                <button class="back-button" data-behavior="show_entries_panel">
                    <%= svg_tag "icon-arrow" %>
                </button>
                <button class="entry-button button-full-screen" data-behavior="full_screen" title="Exit full screen" data-toggle="tooltip">
                    <%= svg_tag "icon-close" %>
                </button>
                <%= entry_presenter.feed_wrapper(subscriptions) do %>
                    <%= entry_presenter.favicon(entry.feed, entry) %>
                    <%= entry_presenter.entry_header_title %>
                <% end %>
            </div>
            <div class="entry-buttons">
                <%= render partial: "entries/delete_button", locals: {entry: entry} %>
                <%# render partial: "shared/mute_button" %>
                <%= render partial: "sharing_services/sharing_service_button" %>
                <%= render partial: "entries/toggle_content", locals: {extract: extract, entry: entry} %>
                <%= render partial: "starred_entries/form", locals: {entry: entry} %>
                <%= render partial: "unread_entries/form", locals: {entry: entry} %>
                <%= render partial: "shared/entry_settings_button" %>
                <%= render partial: "shared/app_settings" %>
            </div>
        </div>
    <% end %>
    <script>
        try {
            feedbin.selectedEntryData = <%= raw json_escape({id: entry.id, url: entry.fully_qualified_url, title: entry.title, feed_id: entry.feed_id, feed_title: entry.feed.title, twitter_id: entry.twitter_id || ""}.to_json) %>;
            feedbin.prepareShareMenu(feedbin.selectedEntryData);
            feedbin.faviconColors($(".entry-toolbar"));
        } catch (e) {
            console.log(e);
        }
    </script>
<% end %>
